﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace QLNhaThuoc.MyClass
{
    abstract class SearchStrategy
    {
        private string _field;
        private string _value;
        protected ISearchVisitor _visitor;

        public string Field
        {
            get { return _field; }
            set { _field = value; }
        }

        public string Value
        {
            get { return _value; }
            set { _value = value; }
        }

        public ISearchVisitor Visitor
        {
            set { _visitor = value; }
        }

        public void SetParameter(string field, string value)
        {
            _field = field;
            _value = value;
        }

        public abstract string GetSearchExpression();
        protected abstract string GetSearchExpression(ISearchVisitor visitor);
    }
}
